#include "awtk.h"
#include "base/assets_manager.h"
#ifndef WITH_FS_RES
#include "assets/default/inc/ui/home_page.data"
#include "assets/default/inc/ui/system_bar.data"
#include "assets/default/inc/ui/window_bar.data"
#include "assets/default/inc/ui/window_line.data"
#include "assets/default/inc/ui/window_meter.data"
#include "assets/default/inc/ui/window_pie.data"
#include "assets/default/inc/strings/en_US.data"
#include "assets/default/inc/strings/zh_CN.data"
#include "assets/default/inc/styles/default.data"
#ifdef WITH_STB_IMAGE
//#include "assets/default/inc/images/arrow_down_d.res"
//#include "assets/default/inc/images/arrow_down_f.res"
//#include "assets/default/inc/images/arrow_down_n.res"
//#include "assets/default/inc/images/arrow_down_o.res"
//#include "assets/default/inc/images/arrow_down_p.res"
//#include "assets/default/inc/images/arrow_left_d.res"
//#include "assets/default/inc/images/arrow_left_f.res"
//#include "assets/default/inc/images/arrow_left_n.res"
//#include "assets/default/inc/images/arrow_left_o.res"
//#include "assets/default/inc/images/arrow_left_p.res"
//#include "assets/default/inc/images/arrow_right_d.res"
//#include "assets/default/inc/images/arrow_right_f.res"
//#include "assets/default/inc/images/arrow_right_n.res"
//#include "assets/default/inc/images/arrow_right_o.res"
//#include "assets/default/inc/images/arrow_right_p.res"
//#include "assets/default/inc/images/arrow_up_d.res"
//#include "assets/default/inc/images/arrow_up_f.res"
//#include "assets/default/inc/images/arrow_up_n.res"
//#include "assets/default/inc/images/arrow_up_o.res"
//#include "assets/default/inc/images/arrow_up_p.res"
//#include "assets/default/inc/images/backspace.res"
//#include "assets/default/inc/images/back_normal.res"
//#include "assets/default/inc/images/back_pressed.res"
//#include "assets/default/inc/images/bg_main.res"
//#include "assets/default/inc/images/clock_bg.res"
//#include "assets/default/inc/images/graph_normal_en.res"
//#include "assets/default/inc/images/graph_normal_zh.res"
//#include "assets/default/inc/images/graph_pressed_en.res"
//#include "assets/default/inc/images/graph_pressed_zh.res"
//#include "assets/default/inc/images/guage_bg.res"
//#include "assets/default/inc/images/guage_bg_1.res"
//#include "assets/default/inc/images/guage_bg_2.res"
//#include "assets/default/inc/images/guage_pointer.res"
//#include "assets/default/inc/images/guage_pointer_1.res"
//#include "assets/default/inc/images/guage_pointer_2.res"
//#include "assets/default/inc/images/histogram_normal_en.res"
//#include "assets/default/inc/images/histogram_normal_zh.res"
//#include "assets/default/inc/images/histogram_pressed_en.res"
//#include "assets/default/inc/images/histogram_pressed_zh.res"
//#include "assets/default/inc/images/icon_1_normal.res"
//#include "assets/default/inc/images/icon_1_pressed.res"
//#include "assets/default/inc/images/icon_2_normal.res"
//#include "assets/default/inc/images/icon_2_pressed.res"
//#include "assets/default/inc/images/icon_3_normal.res"
//#include "assets/default/inc/images/icon_3_pressed.res"
//#include "assets/default/inc/images/icon_4_normal.res"
//#include "assets/default/inc/images/icon_4_pressed.res"
//#include "assets/default/inc/images/icon_5_normal.res"
//#include "assets/default/inc/images/icon_5_pressed.res"
//#include "assets/default/inc/images/icon_6_normal.res"
//#include "assets/default/inc/images/icon_6_pressed.res"
//#include "assets/default/inc/images/language_en.res"
//#include "assets/default/inc/images/language_zh.res"
//#include "assets/default/inc/images/logo.res"
//#include "assets/default/inc/images/meter_normal_en.res"
//#include "assets/default/inc/images/meter_normal_zh.res"
//#include "assets/default/inc/images/meter_pressed_en.res"
//#include "assets/default/inc/images/meter_pressed_zh.res"
//#include "assets/default/inc/images/new_normal.res"
//#include "assets/default/inc/images/new_pressed.res"
//#include "assets/default/inc/images/numdot.res"
//#include "assets/default/inc/images/pause_mormal.res"
//#include "assets/default/inc/images/pause_pressed.res"
//#include "assets/default/inc/images/pie_label_normal.res"
//#include "assets/default/inc/images/pie_label_select.res"
//#include "assets/default/inc/images/pie_normal_en.res"
//#include "assets/default/inc/images/pie_normal_zh.res"
//#include "assets/default/inc/images/pie_pressed_en.res"
//#include "assets/default/inc/images/pie_pressed_zh.res"
//#include "assets/default/inc/images/play_normal.res"
//#include "assets/default/inc/images/play_pressed.res"
//#else
#include "assets/default/inc/images/arrow_down_d.data"
#include "assets/default/inc/images/arrow_down_f.data"
#include "assets/default/inc/images/arrow_down_n.data"
#include "assets/default/inc/images/arrow_down_o.data"
#include "assets/default/inc/images/arrow_down_p.data"
#include "assets/default/inc/images/arrow_left_d.data"
#include "assets/default/inc/images/arrow_left_f.data"
#include "assets/default/inc/images/arrow_left_n.data"
#include "assets/default/inc/images/arrow_left_o.data"
#include "assets/default/inc/images/arrow_left_p.data"
#include "assets/default/inc/images/arrow_right_d.data"
#include "assets/default/inc/images/arrow_right_f.data"
#include "assets/default/inc/images/arrow_right_n.data"
#include "assets/default/inc/images/arrow_right_o.data"
#include "assets/default/inc/images/arrow_right_p.data"
#include "assets/default/inc/images/arrow_up_d.data"
#include "assets/default/inc/images/arrow_up_f.data"
#include "assets/default/inc/images/arrow_up_n.data"
#include "assets/default/inc/images/arrow_up_o.data"
#include "assets/default/inc/images/arrow_up_p.data"
#include "assets/default/inc/images/backspace.data"
#include "assets/default/inc/images/back_normal.data"
#include "assets/default/inc/images/back_pressed.data"
#include "assets/default/inc/images/bg_main.data"
#include "assets/default/inc/images/clock_bg.data"
#include "assets/default/inc/images/graph_normal_en.data"
#include "assets/default/inc/images/graph_normal_zh.data"
#include "assets/default/inc/images/graph_pressed_en.data"
#include "assets/default/inc/images/graph_pressed_zh.data"
#include "assets/default/inc/images/guage_bg.data"
#include "assets/default/inc/images/guage_bg_1.data"
#include "assets/default/inc/images/guage_bg_2.data"
#include "assets/default/inc/images/guage_pointer.data"
#include "assets/default/inc/images/guage_pointer_1.data"
#include "assets/default/inc/images/guage_pointer_2.data"
#include "assets/default/inc/images/histogram_normal_en.data"
#include "assets/default/inc/images/histogram_normal_zh.data"
#include "assets/default/inc/images/histogram_pressed_en.data"
#include "assets/default/inc/images/histogram_pressed_zh.data"
#include "assets/default/inc/images/icon_1_normal.data"
#include "assets/default/inc/images/icon_1_pressed.data"
#include "assets/default/inc/images/icon_2_normal.data"
#include "assets/default/inc/images/icon_2_pressed.data"
#include "assets/default/inc/images/icon_3_normal.data"
#include "assets/default/inc/images/icon_3_pressed.data"
#include "assets/default/inc/images/icon_4_normal.data"
#include "assets/default/inc/images/icon_4_pressed.data"
#include "assets/default/inc/images/icon_5_normal.data"
#include "assets/default/inc/images/icon_5_pressed.data"
#include "assets/default/inc/images/icon_6_normal.data"
#include "assets/default/inc/images/icon_6_pressed.data"
#include "assets/default/inc/images/language_en.data"
#include "assets/default/inc/images/language_zh.data"
//#include "assets/default/inc/images/logo.data"
#include "assets/default/inc/images/meter_normal_en.data"
#include "assets/default/inc/images/meter_normal_zh.data"
#include "assets/default/inc/images/meter_pressed_en.data"
#include "assets/default/inc/images/meter_pressed_zh.data"
#include "assets/default/inc/images/new_normal.data"
#include "assets/default/inc/images/new_pressed.data"
#include "assets/default/inc/images/numdot.data"
#include "assets/default/inc/images/pause_mormal.data"
#include "assets/default/inc/images/pause_pressed.data"
#include "assets/default/inc/images/pie_label_normal.data"
#include "assets/default/inc/images/pie_label_select.data"
#include "assets/default/inc/images/pie_normal_en.data"
#include "assets/default/inc/images/pie_normal_zh.data"
#include "assets/default/inc/images/pie_pressed_en.data"
#include "assets/default/inc/images/pie_pressed_zh.data"
#include "assets/default/inc/images/play_normal.data"
#include "assets/default/inc/images/play_pressed.data"
#endif /*WITH_STB_IMAGE*/
#ifdef WITH_VGCANVAS
#endif /*WITH_VGCANVAS*/
#ifdef WITH_TRUETYPE_FONT
#include "assets/default/inc/fonts/default.res"
#else /*WITH_TRUETYPE_FONT*/
#include "assets/default/inc/fonts/default_18.data"
#endif /*WITH_TRUETYPE_FONT*/
#endif /*WITH_FS_RES*/

ret_t assets_init(void) {
  assets_manager_t* am = assets_manager();
  assets_manager_set_theme(am, "default");

#ifdef WITH_FS_RES
  assets_manager_preload(am, ASSET_TYPE_STYLE, "default");
#else
  assets_manager_add(am, ui_home_page);
  assets_manager_add(am, ui_system_bar);
  assets_manager_add(am, ui_window_bar);
  assets_manager_add(am, ui_window_line);
  assets_manager_add(am, ui_window_meter);
  assets_manager_add(am, ui_window_pie);
  assets_manager_add(am, strings_en_US);
  assets_manager_add(am, strings_zh_CN);
  assets_manager_add(am, style_default);
  assets_manager_add(am, image_arrow_down_d);
  assets_manager_add(am, image_arrow_down_f);
  assets_manager_add(am, image_arrow_down_n);
  assets_manager_add(am, image_arrow_down_o);
  assets_manager_add(am, image_arrow_down_p);
  assets_manager_add(am, image_arrow_left_d);
  assets_manager_add(am, image_arrow_left_f);
  assets_manager_add(am, image_arrow_left_n);
  assets_manager_add(am, image_arrow_left_o);
  assets_manager_add(am, image_arrow_left_p);
  assets_manager_add(am, image_arrow_right_d);
  assets_manager_add(am, image_arrow_right_f);
  assets_manager_add(am, image_arrow_right_n);
  assets_manager_add(am, image_arrow_right_o);
  assets_manager_add(am, image_arrow_right_p);
  assets_manager_add(am, image_arrow_up_d);
  assets_manager_add(am, image_arrow_up_f);
  assets_manager_add(am, image_arrow_up_n);
  assets_manager_add(am, image_arrow_up_o);
  assets_manager_add(am, image_arrow_up_p);
  assets_manager_add(am, image_backspace);
  assets_manager_add(am, image_back_normal);
  assets_manager_add(am, image_back_pressed);
  assets_manager_add(am, image_bg_main);
  assets_manager_add(am, image_clock_bg);
  assets_manager_add(am, image_graph_normal_en);
  assets_manager_add(am, image_graph_normal_zh);
  assets_manager_add(am, image_graph_pressed_en);
  assets_manager_add(am, image_graph_pressed_zh);
  assets_manager_add(am, image_guage_bg);
  assets_manager_add(am, image_guage_bg_1);
  assets_manager_add(am, image_guage_bg_2);
  assets_manager_add(am, image_guage_pointer);
  assets_manager_add(am, image_guage_pointer_1);
  assets_manager_add(am, image_guage_pointer_2);
  assets_manager_add(am, image_histogram_normal_en);
  assets_manager_add(am, image_histogram_normal_zh);
  assets_manager_add(am, image_histogram_pressed_en);
  assets_manager_add(am, image_histogram_pressed_zh);
  assets_manager_add(am, image_icon_1_normal);
  assets_manager_add(am, image_icon_1_pressed);
  assets_manager_add(am, image_icon_2_normal);
  assets_manager_add(am, image_icon_2_pressed);
  assets_manager_add(am, image_icon_3_normal);
  assets_manager_add(am, image_icon_3_pressed);
  assets_manager_add(am, image_icon_4_normal);
  assets_manager_add(am, image_icon_4_pressed);
  assets_manager_add(am, image_icon_5_normal);
  assets_manager_add(am, image_icon_5_pressed);
  assets_manager_add(am, image_icon_6_normal);
  assets_manager_add(am, image_icon_6_pressed);
  assets_manager_add(am, image_language_en);
  assets_manager_add(am, image_language_zh);
//  assets_manager_add(am, image_logo);
  assets_manager_add(am, image_meter_normal_en);
  assets_manager_add(am, image_meter_normal_zh);
  assets_manager_add(am, image_meter_pressed_en);
  assets_manager_add(am, image_meter_pressed_zh);
  assets_manager_add(am, image_new_normal);
  assets_manager_add(am, image_new_pressed);
  assets_manager_add(am, image_numdot);
  assets_manager_add(am, image_pause_mormal);
  assets_manager_add(am, image_pause_pressed);
  assets_manager_add(am, image_pie_label_normal);
  assets_manager_add(am, image_pie_label_select);
  assets_manager_add(am, image_pie_normal_en);
  assets_manager_add(am, image_pie_normal_zh);
  assets_manager_add(am, image_pie_pressed_en);
  assets_manager_add(am, image_pie_pressed_zh);
  assets_manager_add(am, image_play_normal);
  assets_manager_add(am, image_play_pressed);
#ifdef WITH_VGCANVAS
#endif /*WITH_VGCANVAS*/
#ifdef WITH_TRUETYPE_FONT
  assets_manager_add(am, font_default);
#else /*WITH_TRUETYPE_FONT*/
  assets_manager_add(am, font_default_18);
#endif /*WITH_TRUETYPE_FONT*/
#endif

  tk_init_assets();
  return RET_OK;
}
